<%
logoWidth == () ? ( logoWidth=170; ); //todo:remove me
logoColor == () ? ( logoColor='#ffffff'; );

color=? ( '#'+($:!(hex(max{0,min{0+$*256,255}})<<-2)) );
color3d=? ( [{color,pos}]$; .factor=/*{1.5,0.82,0.75,0.9}*/{0.45,-0.162,-0.225,-0.09}[$.pos]; color($.color:!$+factor) ); 
color3dset= ? ( ''+(ctup(4):!color3d{$2,$}+' ') );
convertHTMLColor= ? ( .c=$-'#'; ctup(3):! 1.0*checkedEval('0x'+(c<<$*2>>-2))!/256);
css3d=? ('background-color:'+ color! + '; border:2px solid; border-color: '+ color3dset!); 
%>
body
{
  	font-family: Georgia, Verdana, Arial, Helvetica, sans-serif;
  	font-size: 12pt;
    margin: 0px;
    top:0px;
    padding:8px;
}
body.online
{
    background-image: url(background.jpg); 
    background-repeat: repeat;
    padding:0px; 
}
form
{   margin: 0px;
    padding: 0px;
}
div.logo
{
    float:right; 
    width:<%=logoWidth%>px; 
    padding: 0px 0px 5px 5px;
}
div.border, div.borderOpenAtTop, div.borderOpenAtTopRight, div.borderOpenAtBottom
{ border: 1px solid black;
}

div.borderOpenAtTop { border-top-width:0; }
div.borderOpenAtTopRight { border-width:0 0 1px 1px; }

div.logoBox
{
    <%=css3d(convertHTMLColor(logoColor))%>;
    border-width:0 0 2px 2px;
    text-align:center;
}
div.navigator
{
    padding: 0px <%=logoWidth+6%>px 5px 5px;
}
div.navigatorBox
{
    <%=css3d{ 0.996094, 0.949219, 0.906250 }%>;
    padding:3px;
    border-top-width:0px;
}
div.tab
{
    position:relative;
    padding: 0px 5px 0px 5px; 
    z-index:1;
    height:22px;
}
div.tabBox
{
    <%=css3d{ 0.843750, 0.906250, 0.996094 }%>; 
    padding:2px 5px 2px 5px; 
    border-bottom-width:0px;
    font-size: 18px;
		font-family: sans-serif;
		font-weight: bold;
}
div.tabBoxMinor
{
    <%=css3d{ 0.803750, 0.866250, 0.956094 }%>; 
    padding:1px 5px 0px 5px; 
    border-bottom-width:0px;
		font-family: sans-serif;
    font-size: 15px;
		font-weight: bold;
}
div.tabBorder, div.menuBorder { border: 1px solid black; border-bottom-width:0;}
div.tabBorder { position:absolute;}

div.resource
{   position: relative; 
    padding: 0px 5px 5px 5px;
    top:3px;
    margin-bottom:5px;
}
div.resourceBox
{   <%=css3d{ 0.843750, 0.906250, 0.996094 }%>;
    padding:5px;
}
div.resourceInbox
{ width: 100%;
	position:relative;
}

div.banner
{   padding:0 10px 0 10px;
}
div.content, div.header, ul.stats, div.editHeader
{   background-color: #fff3e8;
}
div.content
{
    margin: 5px 0 5px 0;
    padding: 3px;
}
div.centering { text-align:center; } 

ul.stats
{   margin:0px;
    line-height:1.5em;margin-top:1px;margin-bottom:1px;
    padding:5px 0 5px 20px;
}

div.header
{   padding:7px;
}
div.editHeader
{   padding:3px;
}
p
{
	margin: 0 0 10px 0;
}
p.statHdr
{   margin: 5px 0 2px 0;
		font-family: Sans-serif;
    font-weight: bold;
}
div.historyElem
{   margin: 10px 0 0 0;
}
div.smallPlane
{   padding:20px;width:300px;margin-left: auto; margin-right: auto;text-align:left;
}

div.textBox
{ padding: 9px 6px 9px 6px;
	background-color: #ffffff;
	border: 1px solid #aa9988;
  line-height: 130%;
	height:100%;
}

font.reslist {
  background-color:#fffbf8;
	border: 1px solid #aa9988;
  padding:1px;
  line-height: 150%;
}
font.added {
	color:#006600;
}
font.removed {
	color:#660000;text-decoration: line-through;
}

div.textBox > *:first-child
{
  margin-top: 5px;
}

#gotobtn, #searchbtn
{
	width:110px;height:24px; background-color:#e4d9d9;
}
#searchbtn
{
	width:70px;
}

font.small, span.statAdd {
	font-family: Verdana, Arial, Helvetica, sans-serif;
	font-size: 8pt;
  line-height:2em;
  font-weight:normal;
}
font.warning
{   color:#bb0000;
    font-weight:bold;
    font-size: 16px;
}

a.action, a.hidden {
	font-family: sans-serif;
  background-color: #e4d9d9;
  padding: 1px 4px 1px 4px;
  border-left: 1px solid white;
  border-right: 1px solid black;
  border-top: 1px solid white;
  border-bottom: 1px solid black;
}
a.action:hover,a.action:visited,a.action:link,a.hidden:hover,a.hidden:visited,a.hidden:link
{ color: black;
}
a.hidden {
  display: none;
}
a.action {
  display: inline;
}
a:link, a:visited, a:hover {
	text-decoration: none;
}
a:link {
	color: #0000ee;
}
a:hover {
	background: #fffefd;
	color: #0000ff;
}
a:visited {
	color: #aa00cc;
}
h1 {
	font-size: 24px;
}
h2 {
	font-size: 20px;
}
h3 {
	font-size: 16px;
}
pre,code {
  line-height:120%;
}

table {
  border-collapse: collapse; 
}

table.wiki, img.wiki, div.login {
  border: 2px solid #aa9988;
}

td {
	vertical-align: top;
}

table.wiki td { 
  padding: 3px;
  border: 1px solid #aa9988; 
} 
td.x { 
  background-color: #fff4e0; 
} 

.menuHldr {
	margin:0;
	position:relative;
	padding: 0px 5px 0px 5px; 
	z-index:1;
	height:22px;
}
.menuHldr ul {
	margin:0;
	padding:0;
	position:absolute;
	list-style-type: none;
}
.menuHldr li {
	margin: 0;
	padding: 0 20px 0 0;
	float:left;
}
#nav li.minor {
	padding: 3px 5px 0 0;
}
#nav ul {
	padding:0;margin:0;list-style:none;
	background-color:#eeeeff;
} 
#nav a, #nav input {
	display:block;
	padding:0 0 0 5px;
	width:6em;
}
#nav li ul li{
	padding:0;
	width:5em;
}

#nav li ul
{ position:absolute;
	width:5em;
	left:-999em;
}
#nav li:hover ul, #nav li.sfhover ul
{	left:auto;
}
#nav li:hover, #nav li.hover
{	position: static;
}
#rightunder
{
	position:absolute;
	bottom:0px;
	right:0px;
	padding-bottom:2px;
}
.chapEdit
{
	font-size:12px;
}